const CONFIG = {
  API_KEY: '',
  SERVER_URL: ''
};

// 初始化配置
(async function initConfig() {
  try {
    const { apiKey, serverUrl } = await chrome.storage.local.get(['apiKey', 'serverUrl']);
    if (apiKey) CONFIG.API_KEY = apiKey;
    if (serverUrl) CONFIG.SERVER_URL = serverUrl;
  } catch (err) {
    console.error('Failed to load config:', err);
  }
})(); 